in a dxl skript i havent wrote is a column: |
Re: AttrType at =find(module, string) Also appears based on what you said, only 10 of the 16 different enumerations have been used. |
Re: AttrType at =find(module, string) |
Re: AttrType at =find(module, string) But my problem is that i should rebuild this script with the Telelogic Publishing Engine and there isn't the function find, can anybody gives me the code what find makes in this example thanks |
Re: AttrType at =find(module, string) SystemAdmin - Thu Jun 04 08:55:19 EDT 2009
The attribute type has 16 possible enumerated values.
// List Attribute Values
/*
*/
DB db = null
DBE dbeResults = null
DBE dbeAttr = null
Buffer resBuf = null
void doList(DB db)
{
resBuf = create
string attr = get(dbeAttr)
Module m = current
Object o = null
//print("Values found for attribute \"" attr"\"\n")
Skip attrValues = createString
string s = ""
for o in m do
{
s = o.attr""
if (!find(attrValues, s))
{
put(attrValues, s, s)
}
}
for s in attrValues do
{
resBuf += "\"" s "\"\n"
}
delete(attrValues)
attrValues = null
set(dbeResults, tempStringOf(resBuf))
delete(resBuf)
resBuf = null
}
db = create(current Module, "List Attribute Values")
label(db, "This utility lists all the different values found for the given attribute.\n")
dbeAttr = field(db, "Attribute:", "", 30, false)
dbeResults = text(db, "Results", "", 60, 150, false)
apply(db,"OK", doList)
realize(db)
show(db)
|